// 部门相关接口
import request from '../utils/request'
// 全部部门
export const getDeptListApi = () => request({ url: '/system/department/findAll' })
// 获取部门列表
export const getDeptApi = (params) => request({ url: '/system/department/findDepartmentList', params })
// 导出部门列表
export const exportDeptApi = () => request({ url: '/system/department/excel', method: 'post', responseType: 'blob' })
// 添加部门 /system/department/add
export const addDeptApi = (data) => request({ url: '/system/department/add', method: 'post', data })
// 删除部门
export const delDeptApi = (id) => request({ url: `/system/department/delete/${id}`, method: 'delete' })
// 获取部门详情
export const getDeptInfoApi = (id) => request({ url: `/system/department/edit/${id}`, method: 'get' })
// 更新部门详情
export const editDeptApi = (id, data) => request({ url: `/system/department/update/${id}`, method: 'put', data })
